import React, { Component } from 'react'

export default class Event extends Component {

  constructor(){
    super();
    this.myhandleClick= this.handleClick.bind(this);
    this.state={
      num:1
    }
  }

 

  // handleClick=(str,event)=> {
  //   console.log(str,event)
  // }

  handleClick(event,str) {
    console.log(str,event)
    // this.state.num;
  }

  render() {
    return (
      <div>
        {/* <button onClick={(e) => this.handleClick('helloworld',e)}>提交</button> */}
        {/* <button onClick={this.handleClick}>提交</button> */}
        {/* <button onClick={this.handleClick.bind(this,'helloworld')}>提交</button> */}
        <button onClick={()=>this.myhandleClick('helloworld')}>提交</button>
      </div>
    )
  }
}
